<?php
/*
	获取活动详情
	电商客商品列表页和商品详情页会调用本方法以获得商品详情
*/
defined('BY_JYA') or exit('error');
list($goods_id,$active_id)=$arguments;
$plugininfo=pdo_get('jy_jdk_goods',array('goodsid'=>$goods_id,'uniacid'=>$_SESSION['uniacid']),array('id','url','materialUrl','unitPrice','commisionRatioWl'));
$goods['active']['url']=$plugininfo['url'];
$goods['active']['materialUrl']=$plugininfo['materialUrl'];
if($this->plugin_exists('jy_weishopke')){
	$set=plugin('jy_weishopke')->plugin_setting('basic');
}
$set['ratio']=$set['ratio']?:'50';
$set['vipratio']=$set['vipratio']?:'90';
$getfee=$plugininfo['commisionRatioWl']*$plugininfo['unitPrice']/100;
$goods['active']['ke_money']=price($getfee*$set['ratio']/100,true);
$goods['active']['keup_money']=price($getfee*$set['vipratio']/100,true);
$goods['active']['ke_title']=$set['ke_title']?:'预估赚';
$goods['active']['typeke']='jd';
return $goods['active'];